<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GtkCellAreaContext</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="index.html" title="GTK+ 3 参考手册">
<link rel="up" href="TreeWidgetObjects.html" title="树、列表和图标网格构件">
<link rel="prev" href="gtk3-GtkCellAreaBox.html" title="GtkCellAreaBox">
<link rel="next" href="gtk3-GtkCellRenderer.html" title="GtkCellRenderer">
<meta name="generator" content="GTK-Doc V1.18 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
<tr valign="middle">
<td><a accesskey="p" href="gtk3-GtkCellAreaBox.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="TreeWidgetObjects.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">GTK+ 3 参考手册</th>
<td><a accesskey="n" href="gtk3-GtkCellRenderer.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr>
<tr><td colspan="5" class="shortcuts">
<a href="#gtk3-GtkCellAreaContext.synopsis" class="shortcut">Top</a>
                   | 
                  <a href="#gtk3-GtkCellAreaContext.description" class="shortcut">Description</a>
</td></tr>
</table>
<div class="refentry">
<a name="gtk3-GtkCellAreaContext"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="gtk3-GtkCellAreaContext.top_of_page"></a>GtkCellAreaContext</span></h2>
<p>GtkCellAreaContext — Stores geometrical information for a series of rows in a GtkCellArea</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<a name="gtk3-GtkCellAreaContext.synopsis"></a><h2>Synopsis</h2>
<pre class="synopsis">
#include &lt;gtk/gtk.h&gt;

struct              <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContextClass" title="struct GtkCellAreaContextClass">GtkCellAreaContextClass</a>;
                    <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext">GtkCellAreaContext</a>;
<a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="returnvalue">GtkCellArea</span></a> *       <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-get-area" title="gtk_cell_area_context_get_area ()">gtk_cell_area_context_get_area</a>      (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-allocate" title="gtk_cell_area_context_allocate ()">gtk_cell_area_context_allocate</a>      (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-reset" title="gtk_cell_area_context_reset ()">gtk_cell_area_context_reset</a>         (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-get-preferred-width" title="gtk_cell_area_context_get_preferred_width ()">gtk_cell_area_context_get_preferred_width</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_width</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-get-preferred-height" title="gtk_cell_area_context_get_preferred_height ()">gtk_cell_area_context_get_preferred_height</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-get-preferred-height-for-width" title="gtk_cell_area_context_get_preferred_height_for_width ()">gtk_cell_area_context_get_preferred_height_for_width</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-get-preferred-width-for-height" title="gtk_cell_area_context_get_preferred_width_for_height ()">gtk_cell_area_context_get_preferred_width_for_height</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_width</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-get-allocation" title="gtk_cell_area_context_get_allocation ()">gtk_cell_area_context_get_allocation</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *height</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-push-preferred-width" title="gtk_cell_area_context_push_preferred_width ()">gtk_cell_area_context_push_preferred_width</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> minimum_width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> natural_width</code></em>);
<span class="returnvalue">void</span>                <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-push-preferred-height" title="gtk_cell_area_context_push_preferred_height ()">gtk_cell_area_context_push_preferred_height</a>
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> minimum_height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> natural_height</code></em>);
</pre>
</div>
<div class="refsect1">
<a name="gtk3-GtkCellAreaContext.description"></a><h2>Description</h2>
<p>
The <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> object is created by a given <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a>
implementation via its <a class="link" href="gtk3-GtkCellArea.html#GtkCellAreaClass.create-context"><code class="function">GtkCellAreaClass.create_context()</code></a> virtual
method and is used to store cell sizes and alignments for a series of
<a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a> rows that are requested and rendered in the same context.
</p>
<p>
<a class="link" href="gtk3-GtkCellLayout.html#GtkCellLayout" title="GtkCellLayout"><span class="type">GtkCellLayout</span></a> widgets can create any number of contexts in which to
request and render groups of data rows. However its important that the
same context which was used to request sizes for a given <a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a>
row also be used for the same row when calling other <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a> APIs
such as <a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-render" title="gtk_cell_area_render ()"><code class="function">gtk_cell_area_render()</code></a> and <a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-event" title="gtk_cell_area_event ()"><code class="function">gtk_cell_area_event()</code></a>.
</p>
</div>
<div class="refsect1">
<a name="gtk3-GtkCellAreaContext.details"></a><h2>Details</h2>
<div class="refsect2">
<a name="GtkCellAreaContextClass"></a><h3>struct GtkCellAreaContextClass</h3>
<pre class="programlisting">struct GtkCellAreaContextClass {
  void    (* allocate)                       (GtkCellAreaContext *context,
                                              gint                width,
                                              gint                height);
  void    (* reset)                          (GtkCellAreaContext *context);
  void    (* get_preferred_height_for_width) (GtkCellAreaContext *context,
                                              gint                width,
                                              gint               *minimum_height,
                                              gint               *natural_height);
  void    (* get_preferred_width_for_height) (GtkCellAreaContext *context,
                                              gint                height,
                                              gint               *minimum_width,
                                              gint               *natural_width);
};
</pre>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GtkCellAreaContextClass.allocate"></a>allocate</code></em> ()</span></p></td>
<td>This tells the context that an allocation width or height
(or both) have been decided for a group of rows. The context should
store any allocations for internally aligned cells at this point so
that they dont need to be recalculated at <a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-render" title="gtk_cell_area_render ()"><code class="function">gtk_cell_area_render()</code></a> time.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GtkCellAreaContextClass.reset"></a>reset</code></em> ()</span></p></td>
<td>Clear any previously stored information about requested and
allocated sizes for the context.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GtkCellAreaContextClass.get-preferred-height-for-width"></a>get_preferred_height_for_width</code></em> ()</span></p></td>
<td>Returns the aligned height for the given
width that context must store while collecting sizes for it's rows.</td>
</tr>
<tr>
<td><p><span class="term"><em class="structfield"><code><a name="GtkCellAreaContextClass.get-preferred-width-for-height"></a>get_preferred_width_for_height</code></em> ()</span></p></td>
<td>Returns the aligned width for the given
height that context must store while collecting sizes for it's rows.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="GtkCellAreaContext"></a><h3>GtkCellAreaContext</h3>
<pre class="programlisting">typedef struct {
} GtkCellAreaContext;
</pre>
<p>
</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-get-area"></a><h3>gtk_cell_area_context_get_area ()</h3>
<pre class="programlisting"><a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="returnvalue">GtkCellArea</span></a> *       gtk_cell_area_context_get_area      (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>);</pre>
<p>
Fetches the <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a> this <em class="parameter"><code>context</code></em> was created by.
</p>
<p>
This is generally unneeded by layouting widgets; however
it is important for the context implementation itself to
fetch information about the area it is being used for.
</p>
<p>
For instance at <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContextClass.allocate"><code class="function">GtkCellAreaContextClass.allocate()</code></a> time
its important to know details about any cell spacing
that the <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a> is configured with in order to
compute a proper allocation.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
<td>the <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a> this context was created by. <span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-allocate"></a><h3>gtk_cell_area_context_allocate ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_allocate      (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>);</pre>
<p>
Allocates a width and/or a height for all rows which are to be
rendered with <em class="parameter"><code>context</code></em>.
</p>
<p>
Usually allocation is performed only horizontally or sometimes
vertically since a group of rows are usually rendered side by
side vertically or horizontally and share either the same width
or the same height. Sometimes they are allocated in both horizontal
and vertical orientations producing a homogeneous effect of the
rows. This is generally the case for <a class="link" href="gtk3-GtkTreeView.html#GtkTreeView" title="struct GtkTreeView"><span class="type">GtkTreeView</span></a> when
<span class="type">"fixed-height-mode"</span> is enabled.
</p>
<p>
Since 3.0
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>the allocated width for all <a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a> rows rendered
with <em class="parameter"><code>context</code></em>, or -1.</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>the allocated height for all <a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a> rows rendered
with <em class="parameter"><code>context</code></em>, or -1.</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-reset"></a><h3>gtk_cell_area_context_reset ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_reset         (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>);</pre>
<p>
Resets any previously cached request and allocation
data.
</p>
<p>
When underlying <a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a> data changes its
important to reset the context if the content
size is allowed to shrink. If the content size
is only allowed to grow (this is usually an option
for views rendering large data stores as a measure
of optimization), then only the row that changed
or was inserted needs to be (re)requested with
<a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-get-preferred-width" title="gtk_cell_area_get_preferred_width ()"><code class="function">gtk_cell_area_get_preferred_width()</code></a>.
</p>
<p>
When the new overall size of the context requires
that the allocated size changes (or whenever this
allocation changes at all), the variable row
sizes need to be re-requested for every row.
</p>
<p>
For instance, if the rows are displayed all with
the same width from top to bottom then a change
in the allocated width necessitates a recalculation
of all the displayed row heights using
<a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-get-preferred-height-for-width" title="gtk_cell_area_get_preferred_height_for_width ()"><code class="function">gtk_cell_area_get_preferred_height_for_width()</code></a>.
</p>
<p>
Since 3.0
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody><tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr></tbody>
</table></div>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-get-preferred-width"></a><h3>gtk_cell_area_context_get_preferred_width ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_get_preferred_width
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_width</code></em>);</pre>
<p>
Gets the accumulative preferred width for all rows which have been
requested with this context.
</p>
<p>
After <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-reset" title="gtk_cell_area_context_reset ()"><code class="function">gtk_cell_area_context_reset()</code></a> is called and/or before ever
requesting the size of a <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a>, the returned values are -1.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>minimum_width</code></em> :</span></p></td>
<td>location to store the minimum width,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>natural_width</code></em> :</span></p></td>
<td>location to store the natural width,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-get-preferred-height"></a><h3>gtk_cell_area_context_get_preferred_height ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_get_preferred_height
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_height</code></em>);</pre>
<p>
Gets the accumulative preferred height for all rows which have been
requested with this context.
</p>
<p>
After <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-reset" title="gtk_cell_area_context_reset ()"><code class="function">gtk_cell_area_context_reset()</code></a> is called and/or before ever
requesting the size of a <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a>, the returned values are -1.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>minimum_height</code></em> :</span></p></td>
<td>location to store the minimum height,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>natural_height</code></em> :</span></p></td>
<td>location to store the natural height,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-get-preferred-height-for-width"></a><h3>gtk_cell_area_context_get_preferred_height_for_width ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_get_preferred_height_for_width
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_height</code></em>);</pre>
<p>
Gets the accumulative preferred height for <em class="parameter"><code>width</code></em> for all rows
which have been requested for the same said <em class="parameter"><code>width</code></em> with this context.
</p>
<p>
After <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-reset" title="gtk_cell_area_context_reset ()"><code class="function">gtk_cell_area_context_reset()</code></a> is called and/or before ever
requesting the size of a <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a>, the returned values are -1.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>a proposed width for allocation</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>minimum_height</code></em> :</span></p></td>
<td>location to store the minimum height,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>natural_height</code></em> :</span></p></td>
<td>location to store the natural height,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-get-preferred-width-for-height"></a><h3>gtk_cell_area_context_get_preferred_width_for_height ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_get_preferred_width_for_height
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *minimum_width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *natural_width</code></em>);</pre>
<p>
Gets the accumulative preferred width for <em class="parameter"><code>height</code></em> for all rows which
have been requested for the same said <em class="parameter"><code>height</code></em> with this context.
</p>
<p>
After <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-reset" title="gtk_cell_area_context_reset ()"><code class="function">gtk_cell_area_context_reset()</code></a> is called and/or before ever
requesting the size of a <a class="link" href="gtk3-GtkCellArea.html#GtkCellArea" title="struct GtkCellArea"><span class="type">GtkCellArea</span></a>, the returned values are -1.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>a proposed height for allocation</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>minimum_width</code></em> :</span></p></td>
<td>location to store the minimum width,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>natural_width</code></em> :</span></p></td>
<td>location to store the natural width,
or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-get-allocation"></a><h3>gtk_cell_area_context_get_allocation ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_get_allocation
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> *height</code></em>);</pre>
<p>
Fetches the current allocation size for <em class="parameter"><code>context</code></em>.
</p>
<p>
If the context was not allocated in width or height, or if the
context was recently reset with <a class="link" href="gtk3-GtkCellAreaContext.html#gtk-cell-area-context-reset" title="gtk_cell_area_context_reset ()"><code class="function">gtk_cell_area_context_reset()</code></a>,
the returned value will be -1.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td>
<td>location to store the allocated width, or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td>
<td>location to store the allocated height, or <a href="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. <span class="annotation">[<acronym title="Parameter for returning results. Default is transfer full."><span class="acronym">out</span></acronym>][<acronym title="NULL is ok, both for passing and for returning."><span class="acronym">allow-none</span></acronym>]</span>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-push-preferred-width"></a><h3>gtk_cell_area_context_push_preferred_width ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_push_preferred_width
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> minimum_width</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> natural_width</code></em>);</pre>
<p>
Causes the minimum and/or natural width to grow if the new
proposed sizes exceed the current minimum and natural width.
</p>
<p>
This is used by <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> implementations during
the request process over a series of <a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a> rows to
progressively push the requested width over a series of
<a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-get-preferred-width" title="gtk_cell_area_get_preferred_width ()"><code class="function">gtk_cell_area_get_preferred_width()</code></a> requests.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>minimum_width</code></em> :</span></p></td>
<td>the proposed new minimum width for <em class="parameter"><code>context</code></em>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>natural_width</code></em> :</span></p></td>
<td>the proposed new natural width for <em class="parameter"><code>context</code></em>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
<hr>
<div class="refsect2">
<a name="gtk-cell-area-context-push-preferred-height"></a><h3>gtk_cell_area_context_push_preferred_height ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>                gtk_cell_area_context_push_preferred_height
                                                        (<em class="parameter"><code><a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> *context</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> minimum_height</code></em>,
                                                         <em class="parameter"><code><a href="../glib/glib-Basic-Types.html#gint"><span class="type">gint</span></a> natural_height</code></em>);</pre>
<p>
Causes the minimum and/or natural height to grow if the new
proposed sizes exceed the current minimum and natural height.
</p>
<p>
This is used by <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a> implementations during
the request process over a series of <a class="link" href="gtk3-GtkTreeModel.html#GtkTreeModel" title="GtkTreeModel"><span class="type">GtkTreeModel</span></a> rows to
progressively push the requested height over a series of
<a class="link" href="gtk3-GtkCellArea.html#gtk-cell-area-get-preferred-height" title="gtk_cell_area_get_preferred_height ()"><code class="function">gtk_cell_area_get_preferred_height()</code></a> requests.
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td><p><span class="term"><em class="parameter"><code>context</code></em> :</span></p></td>
<td>a <a class="link" href="gtk3-GtkCellAreaContext.html#GtkCellAreaContext" title="GtkCellAreaContext"><span class="type">GtkCellAreaContext</span></a>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>minimum_height</code></em> :</span></p></td>
<td>the proposed new minimum height for <em class="parameter"><code>context</code></em>
</td>
</tr>
<tr>
<td><p><span class="term"><em class="parameter"><code>natural_height</code></em> :</span></p></td>
<td>the proposed new natural height for <em class="parameter"><code>context</code></em>
</td>
</tr>
</tbody>
</table></div>
<p class="since">Since 3.0</p>
</div>
</div>
</div>
<div class="footer">
<hr>
          Generated by GTK-Doc V1.18</div>
</body>
</html>